package com.lovejes.jesacl.domain.base;

import java.io.Serializable;


/**
 * This is an object that contains data related to the ACLDIC table.
 * Do not modify this class because it will be overwritten if the configuration file
 * related to this class is modified.
 *
 * @hibernate.class
 *  table="ACLDIC"
 * @preserve all
 */

public abstract class BaseAcldic  implements Serializable {

	public static String REF = "Acldic";
	public static String PROP_IDX = "Idx";
	public static String PROP_ID = "Id";
	public static String PROP_VAL = "Val";
	public static String PROP_TIT = "Tit";
	public static String PROP_CODE = "Code";
	public static String PROP_PID = "Pid";


	// constructors
	public BaseAcldic () {
		initialize();
	}

	/**
	 * Constructor for primary key
	 */
	public BaseAcldic (java.lang.String id) {
		this.setId(id);
		initialize();
	}

	protected void initialize () {}



	private int hashCode = Integer.MIN_VALUE;

	// primary key
	private java.lang.String id;

	// fields
	private java.lang.String pid;
	private java.lang.String code;
	private java.lang.String tit;
	private java.lang.String val;
	private java.lang.Integer idx;



	/**
	 * Return the unique identifier of this class
     * @hibernate.id
     *  generator-class="uuid"
     *  column="ID"
     */
	public java.lang.String getId () {
		return id;
	}

	/**
	 * Set the unique identifier of this class
	 * @param id the new ID
	 */
	public void setId (java.lang.String id) {
		this.id = id;
		this.hashCode = Integer.MIN_VALUE;
	}




	/**
	 * Return the value associated with the column: PID
	 */
	public java.lang.String getPid () {
		return pid;
	}

	/**
	 * Set the value related to the column: PID
	 * @param pid the PID value
	 */
	public void setPid (java.lang.String pid) {
		this.pid = pid;
	}



	/**
	 * Return the value associated with the column: CODE
	 */
	public java.lang.String getCode () {
		return code;
	}

	/**
	 * Set the value related to the column: CODE
	 * @param code the CODE value
	 */
	public void setCode (java.lang.String code) {
		this.code = code;
	}



	/**
	 * Return the value associated with the column: TIT
	 */
	public java.lang.String getTit () {
		return tit;
	}

	/**
	 * Set the value related to the column: TIT
	 * @param tit the TIT value
	 */
	public void setTit (java.lang.String tit) {
		this.tit = tit;
	}



	/**
	 * Return the value associated with the column: VAL
	 */
	public java.lang.String getVal () {
		return val;
	}

	/**
	 * Set the value related to the column: VAL
	 * @param val the VAL value
	 */
	public void setVal (java.lang.String val) {
		this.val = val;
	}



	/**
	 * Return the value associated with the column: IDX
	 */
	public java.lang.Integer getIdx () {
		return idx;
	}

	/**
	 * Set the value related to the column: IDX
	 * @param idx the IDX value
	 */
	public void setIdx (java.lang.Integer idx) {
		this.idx = idx;
	}




	public boolean equals (Object obj) {
		if (null == obj) return false;
		if (!(obj instanceof com.lovejes.jesacl.domain.Acldic)) return false;
		else {
			com.lovejes.jesacl.domain.Acldic acldic = (com.lovejes.jesacl.domain.Acldic) obj;
			if (null == this.getId() || null == acldic.getId()) return false;
			else return (this.getId().equals(acldic.getId()));
		}
	}

	public int hashCode () {
		if (Integer.MIN_VALUE == this.hashCode) {
			if (null == this.getId()) return super.hashCode();
			else {
				String hashStr = this.getClass().getName() + ":" + this.getId().hashCode();
				this.hashCode = hashStr.hashCode();
			}
		}
		return this.hashCode;
	}


	public String toString () {
		return super.toString();
	}


}